// 获取图片容器和关闭按钮元素
var headerImage = document.getElementById("headerImage");
var closeButton = document.getElementById("closeButton");

// 页面加载完成后，展开图片
window.onload = function() {
    headerImage.style.height = "400px";
    setTimeout(hideImage, 5000); // 5秒后自动隐藏图片
};

// 点击按钮时，隐藏图片
function hideImage() {
    headerImage.style.height = "0";
}

// 切换手风琴菜单
function toggleAccordion(button) {
    var content = button.nextElementSibling;
    if (content.style.maxHeight) {
        content.style.maxHeight = null;
    } else {
        content.style.maxHeight = content.scrollHeight + "px";
    }
}